package com.aistar.model.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

public class Recruitment implements Serializable {
    private Integer id;

    private String name;

    private String duty;

    private String requirement;

    private String welfare;

    private Integer salaryUpper;

    private Integer salaryLower;

    private String education;

    private String experience;

    private String contactName;

    private String contactPhone;

    private String email;

    private Date releaseTime;

    private Integer frequency;

    private Integer companyId;

    private Integer status;

    private static final long serialVersionUID = 1L;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name == null ? null : name.trim();
    }

    public void setDuty(String duty) {
        this.duty = duty;
    }

    public String getDuty() {
        return duty;
    }

    public void setRequirement(String requirement) {
        this.requirement = requirement;
    }

    public String getRequirement() {
        return requirement;
    }

    public void setWelfare(String welfare) {
        this.welfare = welfare;
    }

    public String getWelfare() {
        return welfare;
    }

    public Integer getSalaryUpper() {
        return salaryUpper;
    }

    public void setSalaryUpper(Integer salaryUpper) {
        this.salaryUpper = salaryUpper;
    }

    public Integer getSalaryLower() {
        return salaryLower;
    }

    public void setSalaryLower(Integer salaryLower) {
        this.salaryLower = salaryLower;
    }

    public String getEducation() {
        return education;
    }

    public void setEducation(String education) {
        this.education = education == null ? null : education.trim();
    }

    public String getExperience() {
        return experience;
    }

    public void setExperience(String experience) {
        this.experience = experience == null ? null : experience.trim();
    }

    public String getContactName() {
        return contactName;
    }

    public void setContactName(String contactName) {
        this.contactName = contactName == null ? null : contactName.trim();
    }

    public String getContactPhone() {
        return contactPhone;
    }

    public void setContactPhone(String contactPhone) {
        this.contactPhone = contactPhone == null ? null : contactPhone.trim();
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email == null ? null : email.trim();
    }

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    public Date getReleaseTime() {
        return releaseTime;
    }

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    public void setReleaseTime(Date releaseTime) {
        this.releaseTime = releaseTime;
    }

    public Integer getFrequency() {
        return frequency;
    }

    public void setFrequency(Integer frequency) {
        this.frequency = frequency;
    }

    public Integer getCompanyId() {
        return companyId;
    }

    public void setCompanyId(Integer companyId) {
        this.companyId = companyId;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", name=").append(name);
        sb.append(", duty=").append(duty);
        sb.append(", requirement=").append(requirement);
        sb.append(", welfare=").append(welfare);
        sb.append(", salaryLower=").append(salaryLower);
        sb.append(", salaryLower=").append(salaryUpper);
        sb.append(", education=").append(education);
        sb.append(", experience=").append(experience);
        sb.append(", contactName=").append(contactName);
        sb.append(", contactPhone=").append(contactPhone);
        sb.append(", email=").append(email);
        sb.append(", releaseTime=").append(releaseTime);
        sb.append(", frequency=").append(frequency);
        sb.append(", companyId=").append(companyId);
        sb.append(", status=").append(status);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}